/**
 * \file example-1.cpp
 * \brief Source file example-1.cpp
 * \author A.TAHIMI
 * \version 0.1
 * \date 23 Nov 2011
 *
 * 1)- Use of header files and libraries : (a.h + liba.so), (a.h + liba.so), (a.h + liba.so).
 *
 * 2)- Use of Ctest.
 *
 */
#include <iostream>
#include <stdlib.h>
#include <a.h>
#include <b.h>
#include <c.h>

using namespace std; 

int main (int argc, char** argv) {
	int upto = 10;  // count to 10 by default
	int i;          // iterator

	// Notice the use of argv[0] (how do we know its the program name?)
	cout << "Inside program " << argv[0] << endl;

	cout << "frome library A : geta() = " << geta() << endl;
	cout << "frome library B : getb() = " << getb() << endl;
	cout << "frome library C : getc() = " << getc() << endl;

	if (argc > 1) { // use first argument
		upto = atoi(argv[1]);
	}

	// perform my count
	for (i = 1; i <= upto; i++) {
		cout << i << endl;
	}

	if (i > 20) {
		return 1;  // what effect does this have? 
	}

	return 0; // successful execution
}
